<div class="sect3">
<h4 id="parameters"><a class="anchor" href="#parameters"></a>parameters<a class="anchorjs-link " href="#parameters" aria-label="Anchor link for: parameters" data-anchorjs-icon="" style="font: 1em/1 anchorjs-icons; padding-left: 0.375em;"></a></h4>
<div class="paragraph">
<p>The <code>parameters</code> directive provides a list of parameters which a user should
provide when triggering the Pipeline. The values for these user-specified
parameters are made available to Pipeline steps via the <code>params</code> object,
see the <a href="#parameters-example">Example</a> for its specific usage.</p>
</div>
<table class="tableblock frame-all grid-all stretch syntax">
<colgroup>
<col style="width: 10%;">
<col style="width: 90%;">
</colgroup>
<tbody>
<tr>
<th class="tableblock halign-center valign-top"><p class="tableblock">Required</p></th>
<td class="tableblock halign-right valign-top"><div class="content"><div class="paragraph">
<p>No</p>
</div></div></td>
</tr>
<tr>
<th class="tableblock halign-center valign-top"><p class="tableblock">Parameters</p></th>
<td class="tableblock halign-right valign-top"><div class="content"><div class="paragraph">
<p><em>None</em></p>
</div></div></td>
</tr>
<tr>
<th class="tableblock halign-center valign-top"><p class="tableblock">Allowed</p></th>
<td class="tableblock halign-right valign-top"><div class="content"><div class="paragraph">
<p>Only once, inside the <code>pipeline</code> block.</p>
</div></div></td>
</tr>
</tbody>
</table>
<div class="sect4">
<h5 id="available-parameters"><a class="anchor" href="#available-parameters"></a>Available Parameters<a class="anchorjs-link " href="#available-parameters" aria-label="Anchor link for: available parameters" data-anchorjs-icon="" style="font: 1em/1 anchorjs-icons; padding-left: 0.375em;"></a></h5>
<div class="dlist">
<dl>
<dt class="hdlist1">string</dt>
<dd>
<p>A parameter of a string type, for example: <code>parameters { string(name: 'DEPLOY_ENV', defaultValue: 'staging', description: '') }</code></p>
</dd>
<dt class="hdlist1">booleanParam</dt>
<dd>
<p>A boolean parameter, for example: <code>parameters { booleanParam(name: 'DEBUG_BUILD', defaultValue: true, description: '') }</code></p>
</dd>
</dl>
</div>
</div>
<div class="sect4">
<h5 id="parameters-example"><a class="anchor" href="#parameters-example"></a>Example<a class="anchorjs-link " href="#parameters-example" aria-label="Anchor link for: parameters example" data-anchorjs-icon="" style="font: 1em/1 anchorjs-icons; padding-left: 0.375em;"></a></h5>
<div class="pipeline-block">  <div class="listingblock pipeline-declarative">
    <div class="title">Jenkinsfile (Declarative Pipeline)</div>
    <div class="content">
  <pre class="CodeRay highlight nowrap"><code class="language-groovy" data-lang="groovy">pipeline {
    agent any
    parameters {
        string(<span style="color:#606">name</span>: <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">'</span><span style="color:#D20">PERSON</span><span style="color:#710">'</span></span>, <span style="color:#606">defaultValue</span>: <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">'</span><span style="color:#D20">Mr Jenkins</span><span style="color:#710">'</span></span>, <span style="color:#606">description</span>: <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">'</span><span style="color:#D20">Who should I say hello to?</span><span style="color:#710">'</span></span>)
    }
    stages {
        stage(<span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">'</span><span style="color:#D20">Example</span><span style="color:#710">'</span></span>) {
            steps {
                echo <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">"</span><span style="color:#D20">Hello </span><span style="background-color:hsla(0,0%,0%,0.07);color:black"><span style="font-weight:bold;color:#666">${</span>params.PERSON<span style="font-weight:bold;color:#666">}</span></span><span style="color:#710">"</span></span>
            }
        }
    }
}</code></pre>
</div></div></div>
<div class="admonitionblock note">
<table>
<tbody><tr>
<td class="icon">
<i class="fa icon-note" title="Note"></i>
</td>
<td class="content">
<div class="paragraph">
<p>A comprehensive list of available parameters is pending the completion of
<a href="https://issues.jenkins-ci.org/browse/INFRA-1053">INFRA-1503</a>.</p>
</div>
</td>
</tr>
</tbody></table>
</div>
</div>
</div>